package com.bianguo.android.apushdemo.model;

import com.bianguo.android.apushdemo.model.impl.MovieModelImpl;

/**
 * Created by Administrator on 2017/4/21.
 */

public class ModelFactory {

    private static ModelFactory factory;

    private ModelFactory(){}

    public static ModelFactory getFactory(){
        synchronized (ModelFactory.class) {
            if (factory == null) {
                synchronized (ModelFactory.class) {
                    if (factory == null) {
                        factory = new ModelFactory();
                    }
                }
            }
        }
        return factory;
    }

    public MovieModelImpl createMovieModel(){
        return new MovieModelImpl();
    }
}
